package com.ruoyi.custom.domain;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Objects;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 商品属性值对象 xking_store_product_attr_value
 * 
 * @author ruoyi
 * @date 2022-08-12
 */
public class StoreProductAttrValue  extends BaseEntity implements Serializable
{
    private static final long serialVersionUID = 1L;

    /** 主键id */
    private Long id;

    /** 商品ID */
    @Excel(name = "商品ID")
    private String productId;

    /** 商品属性索引值 (attr_value|attr_value[|....]) */
    @Excel(name = "商品属性索引值 (attr_value|attr_value[|....])")
    private String specs;

    /** 属性对应的库存 */
    @Excel(name = "属性对应的库存")
    private String stock;

    /** 销量 */
    @Excel(name = "销量")
    private String sales;

    /** 属性金额 */
    @Excel(name = "属性金额")
    private BigDecimal price;

    /** 图片 */
    @Excel(name = "图片")
    private String image;

    /** 唯一值 */
    @Excel(name = "唯一值")
    private String uniqueValue;

    /** 成本价 */
    @Excel(name = "成本价")
    private BigDecimal cost;

    /** 商品条码 */
    @Excel(name = "商品条码")
    private String barCode;

    /** 原价 */
    @Excel(name = "原价")
    private BigDecimal otPrice;

    /** 会员专享价 */
    @Excel(name = "会员专享价")
    private BigDecimal vipPrice;

    /** 重量 */
    @Excel(name = "重量")
    private BigDecimal weight;

    /** 体积 */
    @Excel(name = "体积")
    private BigDecimal volume;

    /** 一级返佣 */
    @Excel(name = "一级返佣")
    private BigDecimal brokerage;

    /** 二级返佣 */
    @Excel(name = "二级返佣")
    private BigDecimal brokerageTwo;

    /** 活动类型 0=商品，1=秒杀，2=砍价，3=拼团 */
    @Excel(name = "活动类型 0=商品，1=秒杀，2=砍价，3=拼团")
    private Integer type;

    /** 活动限购数量 */
    @Excel(name = "活动限购数量")
    private Long quota;

    /** 活动限购数量显示 */
    @Excel(name = "活动限购数量显示")
    private Long quotaShow;

    /** 是否虚拟商品 */
    @Excel(name = "是否虚拟商品")
    private Integer isVirtual;

    /** 优惠券id */
    @Excel(name = "优惠券id")
    private Long couponId;

    /** 虚拟信息内容 */
    @Excel(name = "虚拟信息内容")
    private String diskInfo;

    public void setId(Long id)
    {
        this.id = id;
    }

    public Long getId() 
    {
        return id;
    }
    public void setProductId(String productId) 
    {
        this.productId = productId;
    }

    public String getProductId() 
    {
        return productId;
    }
    public void setSpecs(String specs) 
    {
        this.specs = specs;
    }

    public String getSpecs() 
    {
        return specs;
    }
    public void setStock(String stock) 
    {
        this.stock = stock;
    }

    public String getStock() 
    {
        return stock;
    }
    public void setSales(String sales) 
    {
        this.sales = sales;
    }

    public String getSales() 
    {
        return sales;
    }
    public void setPrice(BigDecimal price) 
    {
        this.price = price;
    }

    public BigDecimal getPrice() 
    {
        return price;
    }
    public void setImage(String image) 
    {
        this.image = image;
    }

    public String getImage() 
    {
        return image;
    }

    public String getUniqueValue() {
        return uniqueValue;
    }

    public void setUniqueValue(String uniqueValue) {
        this.uniqueValue = uniqueValue;
    }

    public void setCost(BigDecimal cost)
    {
        this.cost = cost;
    }

    public BigDecimal getCost() 
    {
        return cost;
    }
    public void setBarCode(String barCode) 
    {
        this.barCode = barCode;
    }

    public String getBarCode() 
    {
        return barCode;
    }
    public void setOtPrice(BigDecimal otPrice) 
    {
        this.otPrice = otPrice;
    }

    public BigDecimal getOtPrice() 
    {
        return otPrice;
    }
    public void setVipPrice(BigDecimal vipPrice) 
    {
        this.vipPrice = vipPrice;
    }

    public BigDecimal getVipPrice() 
    {
        return vipPrice;
    }
    public void setWeight(BigDecimal weight) 
    {
        this.weight = weight;
    }

    public BigDecimal getWeight() 
    {
        return weight;
    }
    public void setVolume(BigDecimal volume) 
    {
        this.volume = volume;
    }

    public BigDecimal getVolume() 
    {
        return volume;
    }
    public void setBrokerage(BigDecimal brokerage) 
    {
        this.brokerage = brokerage;
    }

    public BigDecimal getBrokerage() 
    {
        return brokerage;
    }
    public void setBrokerageTwo(BigDecimal brokerageTwo) 
    {
        this.brokerageTwo = brokerageTwo;
    }

    public BigDecimal getBrokerageTwo() 
    {
        return brokerageTwo;
    }
    public void setType(Integer type) 
    {
        this.type = type;
    }

    public Integer getType() 
    {
        return type;
    }
    public void setQuota(Long quota) 
    {
        this.quota = quota;
    }

    public Long getQuota() 
    {
        return quota;
    }
    public void setQuotaShow(Long quotaShow) 
    {
        this.quotaShow = quotaShow;
    }

    public Long getQuotaShow() 
    {
        return quotaShow;
    }
    public void setIsVirtual(Integer isVirtual) 
    {
        this.isVirtual = isVirtual;
    }

    public Integer getIsVirtual() 
    {
        return isVirtual;
    }
    public void setCouponId(Long couponId) 
    {
        this.couponId = couponId;
    }

    public Long getCouponId() 
    {
        return couponId;
    }
    public void setDiskInfo(String diskInfo) 
    {
        this.diskInfo = diskInfo;
    }

    public String getDiskInfo() 
    {
        return diskInfo;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        StoreProductAttrValue that = (StoreProductAttrValue) o;
        return Objects.equals(id, that.id) && Objects.equals(productId, that.productId) && Objects.equals(specs, that.specs) && Objects.equals(stock, that.stock) && Objects.equals(sales, that.sales) && that.price.compareTo(price) == 0 && Objects.equals(image, that.image) && Objects.equals(uniqueValue, that.uniqueValue) && that.cost.compareTo(cost) == 0 && Objects.equals(barCode, that.barCode) && that.otPrice.compareTo(otPrice) == 0 && Objects.equals(vipPrice, that.vipPrice) &&  that.weight.compareTo(weight) == 0 &&  that.volume.compareTo(volume) == 0 && Objects.equals(brokerage, that.brokerage) && Objects.equals(brokerageTwo, that.brokerageTwo) && Objects.equals(type, that.type) && Objects.equals(quota, that.quota) && Objects.equals(quotaShow, that.quotaShow) && Objects.equals(isVirtual, that.isVirtual) && Objects.equals(couponId, that.couponId) && Objects.equals(diskInfo, that.diskInfo);
    }

    @Override
    public int hashCode() {
        return Objects.hash(id, productId, specs, stock, sales, price, image, uniqueValue, cost, barCode, otPrice, vipPrice, weight, volume, brokerage, brokerageTwo, type, quota, quotaShow, isVirtual, couponId, diskInfo);
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("id", getId())
            .append("productId", getProductId())
            .append("specs", getSpecs())
            .append("stock", getStock())
            .append("sales", getSales())
            .append("price", getPrice())
            .append("image", getImage())
            .append("uniqueValue", getUniqueValue())
            .append("cost", getCost())
            .append("barCode", getBarCode())
            .append("otPrice", getOtPrice())
            .append("vipPrice", getVipPrice())
            .append("weight", getWeight())
            .append("volume", getVolume())
            .append("brokerage", getBrokerage())
            .append("brokerageTwo", getBrokerageTwo())
            .append("type", getType())
            .append("quota", getQuota())
            .append("quotaShow", getQuotaShow())
            .append("isVirtual", getIsVirtual())
            .append("couponId", getCouponId())
            .append("diskInfo", getDiskInfo())
            .append("createTime", getCreateTime())
            .append("updateTime", getUpdateTime())
            .toString();
    }
}
